<h3 class="title">
	&nbsp;首页 &gt; <a href="<?=App::adminUrl('store', 'index', array('res_id' => $res_id));?>"><?=h($storeInfo['name'])?></a> &gt; 菜品管理 &gt; 列表
    <input type="button" style="float:right" onclick="location.href='<?=App::adminUrl('dish', 'import', array('res_id' => $res_id));?>'" class="btn_c" value="批量添加" />
    <!--input type="button" style="float:right" onclick="location.href='<?=App::adminUrl('dish', 'create', array('res_id' => $res_id));?>'" class="btn_c" value="添加菜品" /-->
</h3>

<div class="tags">
  <div id="tagscontent">
    <div id="con_one_1">
      <div class="table_td">
        <form name="listform" id="listform"  action="<?=App::adminUrl('dish', 'batch');?>" method="post">
          <table border="0" cellspacing="2" cellpadding="4" class="formtable" name="table" id="table" width="100%">
            <thead>
              <tr>
                <th><input title="点击可全选本页的所有项目"  onclick="CheckAll(this.form)" type="checkbox" name="chkall" class="checkbox" />
                </th>
                <th>排序</th>
                <th>编号</th>
                <th colspan="2">菜品名称</th>
                <th>价格(元)</th>
                <th>分类</th>
                <th>最后更新</th>
                <th>审核</th>
                <th align="center">操作</th>
              </tr>
            </thead>
            <?php
				foreach($data as $item){
			?>
            <tbody>
              <tr>
                <td align="center"><input onClick="c_chang(this)" type="checkbox" value="<?=$item['dish_id'];?>" name="select[]" class="checkbox" /></td>
                <td align="center"><input type="text" name="listorder[<?=$item['dish_id'];?>]" id="listorder[<?=$item['dish_id'];?>]" value="<?=$item['ordnum'];?>"  size=3/></td>
                <td align="center"><?=$item['dish_id'];?></td>
                <td align="center"><?php if($item['picture']){?><img src="<?=STATIC_URL;?>img/admin/photo.png"><?php } ?></td>
                <td align="left"><a href="#" target="_blank"><?=h($item['name']);?></a><?php if($item['subname']){ echo ' (' .h($item['subname']). ')'; } ?></td>
                <td align="right"><?=number_format($item['price'], 2);?></td>
                <td align="center"><?=h($category[$item['dish_cat_id']]['dish_cat_name']);?></td>
                <td align="center"><?=$item['update_dt'];?></td>
                <td align="center"><? if($item['status']){ ?><font color="Green">√</font><? }else{ ?><font color="Red">×</font><? } ?></td>
                <td align="center"><a href="<?=App::adminUrl('dish','modify', array('res_id'=>$item['res_id'], 'dish_id'=>$item['dish_id']));?>">编辑</a></td>
              </tr>
              <?php
				}
			  ?>
            </tbody>
          </table>

          <div class="blank10"></div>
          <input type="hidden" name="action" id="action" value="">
          <input type="hidden" name="res_id" id="res_id" value="<?=intval($res_id);?>">
          <input type="button" value=" 排序 " name="sort" onClick="$('#action').val('sort'); $('#listform').submit();" class="button" />
          <input type="button" value=" 审核 " name="enable" onClick="if(getSelect(this.form) && confirm('确实要审核ID为('+getSelect(this.form)+')的记录吗?')){$('#action').val('enable');$('#listform').submit();}" class="button" />
          <input type="button" value="取消审核" name="disable" onClick="if(getSelect(this.form) && confirm('确实要取消审核ID为('+getSelect(this.form)+')的记录吗?')){$('#action').val('disable');$('#listform').submit();}" class="button" />
			&nbsp; | &nbsp;
		  <select id="change_dish_cat" name="change_dish_cat" class="ssel">
		  	<option value="">请选择 ...</option>
	        <?php
				foreach($category as $item){
					?><option value="<?=$item['dish_cat_id']?>"><?=$item['dish_cat_name']?></option><?php
				}
			?>
          </select>
          <input type="button" value=" 转移 " name="change" onClick="if(getSelect(this.form) && confirm('确实要移动ID为('+getSelect(this.form)+')的记录吗?')){$('#action').val('change');$('#listform').submit();}" class="button" />

          <div class="blank10"></div>
        </form>
        <div class="page">
	        <?=$pagestring;?>
        </div>
        <div class="clear"></div>
      </div>
      <div id="con_one_2"></div>
    </div>
  </div>
</div>
